home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MacHack 2000
/
MacHack 2000.toast
/
pc
/
The Hacks
/
Softshoe
/
Lisa's Mac Parts
/
Views
/
Panes
/
RectangularPane.h
< prev
next >
Wrap
Text File
|
2000-06-23
|
1KB
|
58 lines
// RectangularPane.h
#ifndef RectangularPane_h
#define RectangularPane_h
#ifndef Pane_h
#include "Pane.h"
#endif
#ifndef Rectangle32_h
#include "Rectangle32.h"
#endif
#ifndef Announcing_h
#include "Announcing.h"
#endif
#ifndef AcceptsSizeSuggestions_h
#include "AcceptsSizeSuggestions.h"
#endif
#ifndef AcceptsConformanceToSize_h
#include "AcceptsConformanceToSize.h"
#endif
class RectangularPane: public Pane,
public AcceptsSizeSuggestions,
public AcceptsConformanceToSize
{
private:
Rectangle32 bounds;
public:
explicit RectangularPane( const DrawsSpontaneously *parent = 0 );
virtual inline void SetContent( View& );
void Clear();
virtual void Adjust( Canvas& ) const;
const Rectangle32& Bounds() const { return bounds; }
void SetBounds( Rectangle32 );
void Deliver( CellVisitor& visitor,
const Canvas& parentCanvas,
Canvas& scratchCanvas,
const Rectangle32& destination ) const
{
if ( destination.Intersects( bounds ) )
Pane::Deliver( visitor, parentCanvas, scratchCanvas );
}
};
inline void RectangularPane::SetContent( View& view )
{
AcceptsSizeSuggestions::SetContent( view );
Pane::SetContent( view );
AcceptsConformanceToSize::SetContent( view );
}
#endif